import { baseRequest } from '@/utils/request'

const request = (url, ...arg) => baseRequest(`/supplier/warehouse/storesstream/` + url, ...arg)

/**
 * 库存流水Api接口管理器
 *
 * @author Mr.wu
 * @date  2025/03/19 09:49
 **/
export default {
	// 获取库存流水分页
	supplierStoresStreamPage(data) {
		return request('page', data, 'get')
	},
	// 提交库存流水表单 edit为true时为编辑，默认为新增
	supplierStoresStreamSubmitForm(data, edit = false) {
		return request(edit ? 'edit' : 'add', data)
	},
	// 删除库存流水
	supplierStoresStreamDelete(data) {
		return request('delete', data)
	},
	// 获取库存流水详情
	supplierStoresStreamDetail(data) {
		return request('detail', data, 'get')
	},
	//批量导出
	supplierStoresStreamExport(data) {
		return request('export',data, 'get',{
			responseType: 'blob'
		})
	}
}
